Inside Macintosh: QuickTime Components

Previous | Chapter Top | Chapter Contents | Next

Setting Source Characteristics

This section discusses the video digitizer component functions that allow applications to set the spatial characteristics of the source video signal. You can use these functions in your application to set and retrieve information about the maximum source rectangle, the active source rectangle, the vertical blanking rectangle, and the digitizer rectangle. For a complete discussion of the relationship between these rectangles, see "About Video Digitizer Components," which begins on About Video Digitizer Components .

You can use the VDGetMaxSrcRect function in your application to get the size and location of the maximum source rectangle. Similarly, the VDGetActiveSrcRect function allows you to get this information about the active source rectangle, and the VDGetVBlankRect function enables you to obtain information about the vertical blanking rectangle.

You can use the VDSetDigitizerRect function to set the size and location of the digitizer rectangle. The VDGetDigitizerRect function lets you retrieve the size and location of this rectangle.

VDGetMaxSrcRect

The VDGetMaxSrcRect function returns the maximum source rectangle.

pascal VideoDigitizerError VDGetMaxSrcRect
                                          (VideoDigitizerComponent ci,
                                         short inputStd,
                                         Rect *maxSrcRect);
ci
Specifies the video digitizer component for the request. Applications obtain this reference from the Component Manager's OpenComponent function.
inputStd
A short integer that specifies the input video signal associated with this maximum source rectangle.
maxSrcRect
Contains a pointer to a rectangle that is to receive the size and location information for the maximum source rectangle.

DESCRIPTION

The maximum source rectangle defines the spatial boundaries of the input video signal. All other rectangles--active source rectangle, digitizer rectangle, and vertical blanking rectangle--are defined relative to the maximum source rectangle. For a complete discussion of the relationship between these rectangles, see "About Video Digitizer Components," which begins on About Video Digitizer Components .

All video digitizer components must support this function.

RESULT CODES

noErr

0

No error

qtParamErr

-2202

Invalid parameter value

VDGetActiveSrcRect

The VDGetActiveSrcRect function allows applications to obtain the size and location information for the active source rectangle used by a video digitizer component.

pascal VideoDigitizerError VDGetActiveSrcRect
                                          (VideoDigitizerComponent ci,
                                         short inputStd,
                                         Rect *activeSrcRect);
ci
Specifies the video digitizer component for the request. Applications obtain this reference from the Component Manager's OpenComponent function.
inputStd
A short integer that specifies the input video signal associated with this maximum source rectangle.
activeSrcRect
Contains a pointer to a rectangle that is to receive the size and location information for the active source rectangle.

DESCRIPTION

The source rectangle is that area in the source video image that contains active video. The video digitizer component returns spatial information that is relative to the maximum source rectangle. For a complete discussion of the relationship between these rectangles, see "About Video Digitizer Components," which begins on About Video Digitizer Components .

All video digitizer components must support this function.

RESULT CODES

noErr

0

No error

qtParamErr

-2202

Invalid parameter value

VDGetVBlankRect

The VDGetVBlankRect function returns the vertical blanking rectangle.

pascal VideoDigitizerError VDGetVBlankRect
                                          (VideoDigitizerComponent ci,
                                         short inputStd,
                                         Rect *vBlankRect);
ci
Specifies the video digitizer component for the request. Applications obtain this reference from the Component Manager's OpenComponent function.
inputStd
Specifies a short integer for the signaling standard used in the source video signal. Valid values are
ntscIn
Input video signal to digitize is in NTSC format
palIn
Input video signal to digitize is in PAL format
secamIn
Input video signal to digitize is in SECAM format
vBlankRect
Contains a pointer to a rectangle that is to receive the size and location information for the vertical blanking rectangle.

DESCRIPTION

The vertical blanking rectangle defines the vertical blanking area in the input video signal, and it corresponds to lines 10 through 19 of the incoming video signal. The video digitizer component returns spatial information that is relative to the maximum source rectangle. For a complete discussion of the relationship between these rectangles, see "About Video Digitizer Components," which begins on About Video Digitizer Components .

All video digitizer components must support this function.

RESULT CODES

noErr

0

No error

qtParamErr

-2202

Invalid parameter value

VDSetDigitizerRect

The VDSetDigitizerRect function allows applications to set the current digitizer rectangle.

pascal VideoDigitizerError VDSetDigitizerRect
                                          (VideoDigitizerComponent ci,
                                          Rect *digitizerRect);
ci
Specifies the video digitizer component for the request. Applications obtain this reference from the Component Manager's OpenComponent function.
digitizerRect
Contains a pointer to a rectangle that contains the size and location information for the digitizer rectangle. The coordinates of this rectangle must be relative to the maximum source rectangle. In addition, the digitizer rectangle must be within the maximum source rectangle.

DESCRIPTION

The current digitizer rectangle defines the area that the digitizer component reads from the input video signal. Applications can crop the input video signal by manipulating this rectangle. The digitizer rectangle coordinates must be specified relative to the maximum source rectangle. Furthermore, the digitizer rectangle must be completely within the maximum source rectangle. For a complete discussion of the relationship between these rectangles, see "About Video Digitizer Components," which begins on About Video Digitizer Components .

All video digitizer components must support this function.

RESULT CODES

noErr

0

No error

qtParamErr

-2202

Invalid parameter value

VDGetDigitizerRect

The VDGetDigitizerRect function returns the current digitizer rectangle.

pascal VideoDigitizerError VDGetDigitizerRect
                                          (VideoDigitizerComponent ci,
                                          Rect *digitizerRect);
ci
Specifies the video digitizer component for the request. Applications obtain this reference from the Component Manager's OpenComponent function.
digitizerRect
Contains a pointer to a rectangle that is to receive the size and location information for the current digitizer rectangle.

DESCRIPTION

The current digitizer rectangle defines the area that the digitizer component reads from the input video signal. The video digitizer component returns spatial information that is relative to the maximum source rectangle. For a complete discussion of the relationship between these rectangles, see "About Video Digitizer Components," which begins on About Video Digitizer Components .

All video digitizer components must support this function.

RESULT CODE

noErr

0

No error


© 1997 Apple Computer, Inc.

Previous | Chapter Top | Chapter Contents | Next